import request from '@/utils/request'

// 获取权限列表
export const getPermissionListAPI = () => {
  return request.get('/sys/permission')
}

// 新增-权限点
export const addPromissionAPI = data => {
  return request.post('/sys/permission', data)
}

// 删除-权限点
export const delPromissionAPI = id => {
  return request.delete(`/sys/permission/${id}`)
}

// 获取-权限点详情
export const getPermissionDetailAPI = id => {
  return request.get(`/sys/permission/${id}`)
}

// 修改-权限点详情
export const updatePromissionAPI = data => {
  return request.put(`/sys/permission/${data.id}`, data)
}
